<?php

namespace App\Models;

use App\Enums\DivideStatus;
use App\Enums\PaymentStatus;
use App\Enums\Payway;
use BenSampo\Enum\Traits\CastsEnums;

/**
 * @mixin IdeHelperOrderPayment
 */
class OrderPayment extends BaseModel
{
    use CastsEnums;

    protected $casts = [
        'pay_status' => PaymentStatus::class,
        'pay_way' => Payway::class,
        'divide_status' => DivideStatus::class,
    ];

    public function order()
    {
        return $this->belongsTo(Order::class);
    }
}
